package com.tom.websocket.pojo;

import java.time.LocalDateTime;

/**
 * @author zx
 * @date 2024年10月18日 10:37
 */
public class ChatMsg {
    /**
     * 发送者的用户ID
     */
    private String senderId;

    /**
     * 接受者的用户ID
     */
    private String receiverId;

    /**
     * 消息接收者的类型,是HR还是求职者,目的为了让前端不同页面接受判断并且处理
     */
    private Integer receiverType;

    /**
     * 聊天内容
     */
    private String msg;

    /**
     * 消息类型,见枚举MsgTypeEnum.java
     */
    private Integer msgType;

    /**
     * 用于消息的签收
     */
    private String msgId;

    /**
     * 消息的聊天时间,即是发送者的发送时间,又是接受者的接收时间
     */
    private LocalDateTime chatTime;

    /**
     * 标记存储数据库,用于历史展示.没超过1分钟,则显示聊天时。前端可以控制时间长短
     */
    private Integer showMsgDateTimeFlag;

    /**
     * 视频地址
     */
    private String videoPath;

    /**
     * 视频宽度
     */
    private Integer videoWidth;

    /**
     * 视频高度
     */
    private Integer videoHeight;

    /**
     * 视频时间
     */
    private Integer videoTimes;

    /**
     * 语音地址
     */
    private String voicePath;

    /**
     * 语音时长
     */
    private Integer speakVoiceDuration;

    /**
     * 语音消息标记是否已读未读,true ： 已读; false: 未读
     */
    private Boolean isRead;

    /**
     * 候选人用户ID
     */
    private String resumeUserId;

    /**
     * 建立名称(候选人名称)
     */
    private String resumeName;

    /**
     * 候选人职位
     */
    private String resumePosition;

    /**
     * 接受者是否在线
     */
    private Boolean isReceiverOnLine;

    public String getSenderId() {
        return senderId;
    }

    public void setSenderId(String senderId) {
        this.senderId = senderId;
    }

    public String getReceiverId() {
        return receiverId;
    }

    public void setReceiverId(String receiverId) {
        this.receiverId = receiverId;
    }

    public Integer getReceiverType() {
        return receiverType;
    }

    public void setReceiverType(Integer receiverType) {
        this.receiverType = receiverType;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public Integer getMsgType() {
        return msgType;
    }

    public void setMsgType(Integer msgType) {
        this.msgType = msgType;
    }

    public String getMsgId() {
        return msgId;
    }

    public void setMsgId(String msgId) {
        this.msgId = msgId;
    }

    public LocalDateTime getChatTime() {
        return chatTime;
    }

    public void setChatTime(LocalDateTime chatTime) {
        this.chatTime = chatTime;
    }

    public Integer getShowMsgDateTimeFlag() {
        return showMsgDateTimeFlag;
    }

    public void setShowMsgDateTimeFlag(Integer showMsgDateTimeFlag) {
        this.showMsgDateTimeFlag = showMsgDateTimeFlag;
    }

    public String getVideoPath() {
        return videoPath;
    }

    public void setVideoPath(String videoPath) {
        this.videoPath = videoPath;
    }

    public Integer getVideoWidth() {
        return videoWidth;
    }

    public void setVideoWidth(Integer videoWidth) {
        this.videoWidth = videoWidth;
    }

    public Integer getVideoHeight() {
        return videoHeight;
    }

    public void setVideoHeight(Integer videoHeight) {
        this.videoHeight = videoHeight;
    }

    public Integer getVideoTimes() {
        return videoTimes;
    }

    public void setVideoTimes(Integer videoTimes) {
        this.videoTimes = videoTimes;
    }

    public String getVoicePath() {
        return voicePath;
    }

    public void setVoicePath(String voicePath) {
        this.voicePath = voicePath;
    }

    public Integer getSpeakVoiceDuration() {
        return speakVoiceDuration;
    }

    public void setSpeakVoiceDuration(Integer speakVoiceDuration) {
        this.speakVoiceDuration = speakVoiceDuration;
    }

    public Boolean getRead() {
        return isRead;
    }

    public void setRead(Boolean read) {
        isRead = read;
    }

    public String getResumeUserId() {
        return resumeUserId;
    }

    public void setResumeUserId(String resumeUserId) {
        this.resumeUserId = resumeUserId;
    }

    public String getResumeName() {
        return resumeName;
    }

    public void setResumeName(String resumeName) {
        this.resumeName = resumeName;
    }

    public String getResumePosition() {
        return resumePosition;
    }

    public void setResumePosition(String resumePosition) {
        this.resumePosition = resumePosition;
    }

    public Boolean getReceiverOnLine() {
        return isReceiverOnLine;
    }

    public void setReceiverOnLine(Boolean receiverOnLine) {
        isReceiverOnLine = receiverOnLine;
    }

    @Override
    public String toString() {
        return "ChatMsg{" +
                "senderId='" + senderId + '\'' +
                ", receiverId='" + receiverId + '\'' +
                ", receiverType=" + receiverType +
                ", msg='" + msg + '\'' +
                ", msgType=" + msgType +
                ", msgId='" + msgId + '\'' +
                ", chatTime=" + chatTime +
                ", showMsgDateTimeFlag=" + showMsgDateTimeFlag +
                ", videoPath='" + videoPath + '\'' +
                ", videoWidth=" + videoWidth +
                ", videoHeight=" + videoHeight +
                ", videoTimes=" + videoTimes +
                ", voicePath='" + voicePath + '\'' +
                ", speakVoiceDuration=" + speakVoiceDuration +
                ", isRead=" + isRead +
                ", resumeUserId='" + resumeUserId + '\'' +
                ", resumeName='" + resumeName + '\'' +
                ", resumePosition='" + resumePosition + '\'' +
                ", isReceiverOnLine=" + isReceiverOnLine +
                '}';
    }
}
